package de.szut.database;

import com.j256.ormlite.android.apptools.OrmLiteConfigUtil;
import de.szut.entity.*;

import java.io.IOException;
import java.sql.SQLException;

/**
 * Run this locally as java file to generate a config file to generate all
 * locale database tables, which will improve the performance of the used
 * library (ormLite) IMPORTANT: Remove the android bootstrap entry and set the
 * JRE version to alternative to be able to run this class NEVER try to run the
 * main class inside the android application, since this wont work
 * <p/>
 * Created by dzebcuks on 19.08.13.
 */
public class DatabaseConfigUtil extends OrmLiteConfigUtil {

    /**
     * Lists of entities to load
     */
    private static final Class<?>[] classes = new Class[]{AbilityTree.class, AbilityUpgrade.class,
            BaseAbility.class, Modifier.class, ModifierValue.class, Country.class, Points.class};

    public static void main(final String[] args) throws SQLException,
            IOException {
        writeConfigFile("ormlite_config.txt", classes);
    }
}
